home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
comm
/
zmax200.zip
/
ZMAX.DOC
< prev
next >
Wrap
Text File
|
1992-03-13
|
11KB
|
265 lines
Zmax Introduction Guide rev. 2.00 Page 1
Zmax
Copyright 1990, 91 Mike Bryeans
All Rights Reserved
Zmax is designed to replace Zmodem. It uses 32 bit CRC's on
file data blocks, the same as Zmodem, and 32 bit CRC's on its
information blocks, Zmodem uses 16 bit.
An information block is a block of data used to send
information about the name of the file, the receivers system
setup, about the next block of actual File Data, etc.
Zmax is setup to allow almost unlimited future expansion to
the protocol while allowing it to remain backwards compatible
with older versions.
In stream mode Zmax sends blocks, the size being set by the
receiver, of data but doesn't require ACKS from the receiver.
Zmax should (depending on equipment, phone lines,
implementation, etc.) allow about 98.5 percent efficiency at
2400 baud on a 30K file compared to Zmodems 95 percent.
And unlike Zmodem, Zmax reaches full speed on considerably
smaller files.
In Non-Stream mode (which can be set by the receiver OR the
sender), Zmax is a super Batch Xmodem or Ymodem depending on
the block size. Super because it uses 32 bit CRC's instead of
16.
Even using Ymax mode (Zmax running 1K blocks with Acks
required), you'll get faster transfers than under Zmodem. In
fact, there wasn't any measurable difference between Ymax
mode and Zmax mode on a 30K transfer. At least none that the
efficiency computation routine showed.
This is at 2400 baud of course. Non-Stream protocols don't
fair near as well (speed wise) as Streamed protocols at
highspeeds.
We'll call Zmax running 128 byte blocks with ACKS Xmax mode.
Running in this mode, you'll get about (maybe a tad better)
Xmodem speed, but with the additional safty of 32bit CRCs.
I'd suggest allowing your users to directly address the size
of the receiver buffers and wheither or not to use ACKS as I
have in the Zmax.c driver so they can customize several
different versions to best fit the conditions they may
encounter.
Zmax Introduction Guide rev. 2.00 Page 2
Why Non-Stream mode? Three reasons and the first being noisy
lines.
Stream protocols don't fair well under noisy lines. If you
can SWITCH to non-stream (ack required) during the course of
the transfer, your efficiency is generally better.
The Second reason is computer type. Some computers can not
handle writing to the disk and receiving data at the same
time.
If your writing a Zmax driver for a computer that falls into
this category, write the block of data to the disk BEFORE you
ACK the block. The sender will wait up to 30 seconds before
assuming an error has occurred.
The third and final reason one may wish to run in non-stream
mode is to allow background tasking by commucations programs.
Although I beleive that STREAM mode can function quick
enough to allow this, if not then you have a method to fall
back on.
As outlined in the code segment, I suggest switching to NON-
Stream mode when your block size reaches 128 bytes. I also
suggest that you not go below 128 bytes. Primarily because
you don't save much. It only takes about 2/10's of a second
longer to send a 128 byte block over a 64 byte block at 2400
baud, less at 9600+.
Unlike Zmodem which sets an upper limit of 1024 bytes on
block sizes, Zmax has an upper limit of over 32K. One
shouldn't go that high, at least with the modems currently
available. Because of this, Zmax may be used as a mailer
protocol without ANY modifications.
Zmax also has a LOT less CPU overhead than Zmodem so slower
computers can drive highspeed modems FASTER.
Zmax does not encode each byte of data like Zmodem does. I
can't see any real advantage to doing this and it reduces the
amount of CPU overhead and simplifies the code quite a bit.
Zmax also treats all files as Binary 8 bit files and will
require word length to be set to 8, which is the most common
setting.
Please pay special attention to the timer functions. They
have been worked out over a two year period of heavy mailer
use under all kinds of conditions and have proven to work
exceptionally well on Networks, Satellite Links, and under
Multi-Taskers. Changing any of them can lead to erratic
behavior on YOUR Zmax implementation.
Zmax Introduction Guide rev. 2.00 Page 3
Zmax uses two block start characters, instead of the
traditional one. I do that to keep a stray character (line
noise) from accidentally triggering something it shouldn't.
Why A Zmodem Replacement in the first place?
Unless your attempting to write a Zmodem driver, you wouldn't
understand.
Zmodem isn't documented very well, in fact the only
documentation that I'm aware of is the original 1988
publication and you'll have a hard time finding that one now.
It left much to the imagination and were little more than a
few sheets of paper glorifying Zmodem. And it only contained
scrap segments of code that few could get to work.
Because of this, Zmodem implementations vary depending on who
wrote it and they aren't always compatible.
And finally: Because of the complexity of the zmodem
protocol, systems with limited memory capablities (Apples,
Color Computers, Commodores, etc.) have a very difficult if
not impossible, time attempting to implement Zmodem in a 64K
environment.
I think actual CODE is better than extensive documentation,
you can actual SEE how its suppose to work, so Zmax.c is
provided when you register the program.
Zmax.c is a full functional Zmax driver. You'll not be able
to simply compile it because I do use my own libraries, most
have Microsoft counter parts. You shouldn't have any trouble
telling WHAT a function does. Zmax.c also contains further
information on specific aspects of Zmax.
Is Zmax compatible with Zmodem?
The answer to that one is no, it is not. This is a
PREPLACEMENT protocol, not just a reworked hack of zmodem. It
has better error detection and it is faster than zmodem.
Zmax Introduction Guide rev. 2.00 Page 4
Zmax.exe
Zmax.exe requires a number of command line switches; -B, -P,
{-R or -F}.
Full Command Line Switch Run Down
-UDrive:path, directs that all files received should be
stored on this drive and in this directory.
This switch is primaryly for NON-OSIRIS,
NON-QT systems. Osiris takes care of this
internally and this switch should NOT be
used.
Example: -UC:\uploads
-UD:\files\temp